import sys
import os
import ctypes


class GetActivation:
    def __init__(self):
        try:
            self.so = ctypes.CDLL("libkylin-activation.so")
        except Exception, e:
            print e

    def get_serial_number(self):
        ret = []
        result = 0
        serial_no = "serial_no"
#        serial_no = self.so.kylin_activation_get_serial_number (result)
        ret.append(str(result))
        ret.append(serial_no)
#        ret.append(serial_no)
        return ret

    def get_register_number(self):
        ret = []
        result = 0
        register_code = "serial_no"
#        register_code = self.so.kylin_activation_get_register_number(result)
        ret.append(str(result))
        ret.append(register_code)
#        ret.append(register_code)
        return ret

    def get_qrcode(self):
        ret = []
        result = 0
        qrcode='qrcode'
#        qrcode = self.so.kylin_activation_get_qrcode(result)
        ret.append(str(result))
        ret.append(qrcode)
#        ret.append(qrcode)
        return ret
    
    def activation_activate_system(self,acti):
#        ret = self.so.kylin_activation_activate_system(acti)
        ret = "kobe"
        return ret
    
